{% extends 'cms/cms_base.html' %}

{% block head %}
{#    以下三个是七牛上传文件需要的js#}
    <script src="https://cdn.staticfile.org/Plupload/2.1.1/moxie.js"></script>
    <script src="https://cdn.staticfile.org/Plupload/2.1.1/plupload.dev.js"></script>
{#    <script src="https://cdn.staticfile.org/qiniu-js-sdk/1.0.14-beta/qiniu.js"></script>#}
    <script src="http://media.junpy.club/static-qiniu.js"></script>
    <script src="{{ url_for('static', filename="common/juneqiniu.js") }}"></script>
    <script src="{{ url_for('static',filename="cms/js/cms_operate_board.js") }}"></script>
{% endblock %}
{% block content_title %}
    六月论坛-板块列表
{% endblock %}
{% block content %}
    <div class="head-box">
        <button class="btn btn-warning pull-right" data-toggle="modal" data-target="#banner-dialog" id="add-board">添加板块</button>
    </div>
    <table class="table table-bordered">
        <tr>
            <th class="text-center">板块名称</th>
            <th class="text-center">帖子数量</th>
            <th class="text-center">创建时间</th>
            <th class="col-md-2 text-center">操作</th>
        </tr>
        {% for board in boards %}
        <tr class="text-center" data-board-id="{{ board.id }}" data-board-name="{{ board.board_name }}">
            <td>{{ board.board_name }}</td>
            <td>0</td>
            <td>{{ board.add_time }}</td>
            <td>
                <button class="btn btn-info btn-sm" id="edit-board-btn">编辑</button>
                <button class="btn btn-danger btn-sm" id="delete-board-btn">删除</button>
            </td>
        </tr>
        {% endfor %}
    </table>
{% endblock %}